package com.hospital.hospitalserver.controller;

import com.hospital.hospitalserver.service.StatisticsService;
import com.hospital.hospitalserver.util.Response;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;

@RestController
@CrossOrigin
@RequiredArgsConstructor
@RequestMapping("/home")
public class HomeController {
    private final StatisticsService statisticsService;

    /**
     * 管理首页数据统计
     * */
    @GetMapping("/getHomeStatsData")
    public Response getHomeStatsData(){
        return statisticsService.getHomeStatsData();
    }
}
